package com.stone.design.patterns.proxy;

/**
 * @description 律师的代理， 持有一个被代理着，调用被代理者的方法
 * @Time 2018/4/20 12:43
 * Created by Stone on 2018/4/20.
 */

public class Lawyer implements ILawsuit {

    private ILawsuit lawsuit;

    public Lawyer(ILawsuit lawsuit) {
        this.lawsuit = lawsuit;
    }

    @Override
    public void submit() {
        lawsuit.submit();
    }

    @Override
    public void burden() {
        lawsuit.burden();
    }

    @Override
    public void defend() {
        lawsuit.defend();
    }

    @Override
    public void finish() {
        lawsuit.finish();
    }
}
